package com.wrx.server.controller;


import com.wrx.server.pojo.*;
import com.wrx.server.service.IBarService;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

import javax.servlet.http.HttpServletRequest;

/**
 * <p>
 *  查询控制器
 * </p>
 *
 * @author wrx
 * @since 2021-04-20
 */
@RestController
public class SearchController {

    @Autowired
    private IBarService barService;


    @ApiOperation(value = "根据模糊吧名搜索贴吧")
    @PostMapping("/Search")
    public RespBean Search(@RequestBody SearchBean searchBean){
//        if (searchBean.getState()==1){
            return barService.selLikeBarByInfo(searchBean.getSearchInfo());
//        }
//        return null;
    }



}
